<template>
  <div class="app-container">
    <!-- <el-table  :data="ticket">
      <el-table-column type="selection" width="55" align="center" />
      <el-table-column label="id" align="center" prop="id" />
      <el-table-column label="组别名称" align="center" prop="title" />
      <el-table-column label="状态" align="center" prop="status" />
      <el-table-column label="是否验证权限" align="center" prop="isManage" />
      <el-table-column label="权限" align="center" prop="rules" />
      
        <el-table-column fixed="right" label="操作" width="100">
         <template slot-scope="scope">
        <el-button @click="handleClick(scope.row)" type="text" size="small">查看</el-button>
        <el-button type="text" size="small">编辑</el-button>
      </template> 
      </el-table-column>
    </el-table> -->
   
  </div>
</template>

<script>
import { getList } from "@/api/group/group";
export default {
    name: "visit",
  data() {
    return{
        // 分页后的当前页数据
        list: [],
        //当前数据页的第几页
        currentPage: 1,
        // 总数据条数
        total: 0,
        // 每页显示多少行数据,默认为10条
        pagesize: 10,
        // 代表是从后端获取的所有数据
        ticket: []
    }
  },
  created() {
        this.getGroups();
  },
  methods:{
         getGroups() {
          //this.listLoading = true;
         getList().then(response => {
            console.log(response.data);
            if(response.code === 200){
                this.ticket = response.data;
                //获取返回数据的总行数
                this.total = response.data.length;
                // 获取当前页的数据,此方法在下方定义
                
                this.$message({
                    message: '数据加载成功',
                    type: 'success'
                })
            } else {
                // 失败提示信息
                this.$$message({
                    message: '数据加载错误',
                    type: 'error'
                })
            }
         });
    },
    handleClick(){
      
    }
  }
}
</script>
    
<style>

</style>